﻿using Service.src.NW.Model.Folw.Database;
using Service.src.NW.Model.Folw.File;
using Service.src.NW.Model.Folw.Logic;
using Service.src.NW.Model.Folw.PLC;

namespace Service.src.NW.Model.Folw
{

    /// <summary>
    /// 节点的数据输入源
    /// </summary>
    public class NodeInputParam : NodeParamDataSource
    {

        /// <summary>
        /// 节点是否继续往下执行的判断条件
        /// </summary>
        public dynamic NodeContinue {  get; set; }

        /// <summary>
        /// 条件程序继续执行
        /// true = 成立
        /// false = 不成立
        /// </summary>
        public bool IsNodeContinue { get; set; } = true;

        /// <summary>
        /// PLC节点的输入参数
        /// </summary>
        public NodePLCInputParam NodePLC { get; set; }

        /// <summary>
        /// MES配置信息
        /// </summary>
        public NodeMesInputParam NodeMes { get; set; }

        /// <summary>
        /// 逻辑运算的入参
        /// </summary>
        public NodeLogicInputParam NodeLogic { get; set; }

        public NodeDatabaseInputParam Database { get; set; }

        public NodeSocketInputParam NodeSocket { get; set; }

        public NodeFileParam NodeFile { get; set; }

        /// <summary>
        /// 公共的/通用的入参，根据实际情况而定
        /// 
        /// 已使用的节点：
        ///     1, 串口节点
        /// </summary>
        public NodeDataSource CommonInput { get; set; }

    }
}
